package com.whq.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.whq.dao.OrderMapper;
import com.whq.entity.Order;
import com.whq.service.OrderService;

@Service(value = "tdOrderService")
public class OrderServiceImpl implements OrderService {

    @Autowired
    private OrderMapper<Order>tdOrderMapper;
    
    @Override
    public Integer insertSelective(Order tdOrder) throws Exception {
           return this.tdOrderMapper.insertSelective(tdOrder);
        }

    @Override
    public Integer insertBatch(List<Order> tdOrder) throws Exception {
           return this.tdOrderMapper.insertBatch(tdOrder) ;
        }

    @Override
    public Integer deleteByPrimaryKey(Object id) {
            return this.tdOrderMapper.deleteByPrimaryKey(id);
    }

    public Integer deleteBatchByPrimaryKey(List<Object> ids) {
           return this.tdOrderMapper.deleteBatchByPrimaryKey(ids);
    }

    @Override
    public Integer updateByPrimaryKeySelective(Order tdOrder) {
           return this.tdOrderMapper.updateByPrimaryKeySelective(tdOrder);
    }

    @Override
    public Order findById(Object id) {
           return (Order) this.tdOrderMapper.selectByPrimaryKey(id);
    }

    @Override
    public List<Order> selectByCondition(Order tdOrder) {
           return (List<Order>) this.tdOrderMapper.selectByCondition(tdOrder);
    }

    @Override
    public Integer selectCountByCondition(Order tdOrder) {
           return  this.tdOrderMapper.selectCountByCondition(tdOrder);
    }

}
